package com.senior.sendmessage.config;

import cn.hutool.core.date.LocalDateTimeUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import javax.annotation.PreDestroy;

/**
 * 关机配置
 * @author baijiliang
 */
@Component
@Slf4j
public class TerminateSystemConfig {

    @PreDestroy
    public void shutdown() {
        log.info("程序已关机，时间：{}", LocalDateTimeUtil.formatNormal(LocalDateTimeUtil.now()));
    }
}
